|
|
Generates geometry for a cube. Allocates memory for the vertex data and stores the results in the arrays. Generate index list for a TRIANGLES.
- Parameters:
-
| scale | The size of the cube, use 1.0 for a unit cube. |
| vertices | If not NULL, will contain array of float3 positions |
| normals | If not NULL, will contain array of float3 normals |
| texCoords | If not NULL, will contain array of float2 texCoords |
| indices | If not NULL, will contain the array of indices for the triangle strip |
- Returns:
- The number of indices required for rendering the buffers (the number of indices stored in the indices array if it is not NULL ) as a GL_TRIANGLE_STRIP
|